<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>requestBatch</title>
</head>
<body>

<div align="center">

    <div>抖音视频</div>
    <div>
        <video src="" controls height="300px" width="500px"></video>
    </div>

    <br/>
    <button id="btn">点我发送一批url给抖音试试</button>
</div>

</body>


<script type="text/javascript">

    // 利用window跳转
    // 利用a标签

    urlArr = [];

    var count = 0;
    let length = urlArr.length;
    console.log("length= " + length);

    const btn = document.getElementById("btn");
    // btn.onclick = function () {
    //
    //
    //     alert("hello~")
    // };

    btn.onclick = function () {

        let url = "";
        console.log("count= " + count);

        for (let i = count; i < count + 10; i++) {
            if (i <= length - 1) {
                console.log("i= " + i);
                console.log("count= " + count);

                url = urlArr[i];
                console.log(url);
                // location.href = url;
                window.open(url);
            }
        }

        count += 10;
    };


</script>
</html>
